<?php 
$this->placeholder('display-commercial1')->set(1);
?>
<?php $this->placeholder('grid-size')->set('12');?>
<?php $this->placeholder('container-class')->set('adDetail job')?>
<?php $this->placeholder('big-section-class')->set('main_section') ?>
<?php $this->headLink()->appendStylesheet(Ac_Util::getImageBaseUrl('/css/custom_ad_detail.v-'.AC_VERSION.'.css'))?>
<script type="text/javascript">var switchTo5x=true;</script>
<?php $this->headScript()->appendFile('http://w.sharethis.com/button/buttons.js')?>
<?php $this->headScript()->appendFile('http://api.map.baidu.com/api?v=1.2&services=true')?>
<?php $this->headScript()->captureStart() ?>
stLight.options({
    publisher:'3d63f5a4-6d39-40bb-9d19-4e15999d0290',
        theme:'7',
        onhover: false
});
<?php $this->headScript()->captureEnd() ?>
<article class="article">
    <section class="main_section">
        <section class="remark"><p><span>卖家<em>华强北甄子丹</em>说：</span>“我要卖呀!!”</p></section>  
        <section class="breadcrumb">
            <dl class="back">
                <dd><a href="#">&lt; Back</a></dd>
            </dl>
            <dl class="path">
                <dt>列于分类：</dt>
                <dd><a href="#">运动及嗜好</a> &raquo; <a href="#">其他</a></dd>
            </dl>
        </section>
        <h1><em><?php echo $this->listing->title?></em><span class="price"><?php echo $this->price($this->listing);?></span><span class="location">位于北京石景山</span></h1>
        <section class="func">
        <a href="<?php echo $this->geturl('like','follow', array('id' => (string)$this->listing->_id))?>" class="like <?php echo Model_Like::isLiked($this->listing->_id) ? 'selected' : ''?>">喜欢<em><?php echo Model_Like::getCount($this->listing->_id)?></em></a>
        <a href="#" class="save">收藏</a>
        <a href="#" class="msg">发讯息</a>
            <!-- JiaThis Button BEGIN -->
            <div id="jiathis_style_32x32">
                <span class="jiathis_txt">分享到：</span>
                <a class="jiathis_button_qzone"></a>
                <a class="jiathis_button_tsina"></a>
                <a class="jiathis_button_tqq"></a>
                <a class="jiathis_button_renren"></a>
                <a class="jiathis_button_kaixin001"></a>
                <a href="http://www.jiathis.com/share" class="jiathis jiathis_txt jtico jtico_jiathis" target="_blank"></a>
                <!--a class="jiathis_counter_style"></a-->
            </div>
            <script type="text/javascript" src="http://v2.jiathis.com/code/jia.js" charset="utf-8"></script>
            <!-- JiaThis Button END -->
    </section>
    <section class="ad">
        <a href="#"><img src="images/ad_728_90.jpg"></a>      
    </section>
    <section class="info">
        <h3>详细资料</h3>
        <section class="general">
            <dl>
                <?php if(!empty($this->listing->company)):?>
                    <dt>刊登者</dt>
                    <dd><a href="<?php echo $this->listing->company->url()?>"><?php echo $this->listing->company->name;?></a></dd>
                <?php endif;?>
                <dt>价格</dt>
                <dd><?php echo $this->price($this->listing, false);?></dd>
                <dt>地址</dt>
                <dd><?php echo $this->listing->address?></dd>
                <dt>地点</dt>
                <dd>北京</dd>
                <dt>刊登日期</dt>
                <dd><?php echo date(MEDIUM_DATE_FORMAT, $this->listing->posted_at)?></dd>
                <dt>观看次数</dt>
                <dd><?php echo $this->listing->number_views?></dd>
            </dl>
        </section>
        <section class="category">
            <h3>工作內容</h3>
            <dl>
                <dt>公司名稱</dt><dd>      
                <figure><img src="images/adDetail_pic.jpg"></figure></dd>        
                <dd>Infotech Services (HK) Limtied</dd>
                <dt>工作性質</dt>        
                <dd>全職</dd>
                <dt>職級要求</dt>        
                <dd>中級</dd>
                <dt>牌子</dt>        
                <dd>Porsche</dd>
                <dt>年資要求</dt>        
                <dd>3-5</dd>
                <dt>教育程度要求</dt>        
                <dd>Non-degree Tertiary</dd>
                <dt>居住狀況</dt>        
                <dd>永久居民</dd>
                <dt>公司福利</dt>        
                <dd>Medical Insurance</dd>
        </dl>
        </section>
        <section class="desc">
            <h3>描述</h3>
            <dl>
                <dd>
                    <?php echo $this->listing->description?>
                </dd>
            </dl>
        </section>
    </section>
    <section class="ad">
      <a href="#"><img src="images/ad_728_90.jpg"></a>      
    </section>  
    <?php if (Model_Like::getCount($this->listing->_id) > 0) :?>
        <section class="like">
            <h3><span><?php echo Model_Like::getCount($this->listing->_id)?></span>人喜欢你的讯息</h3>
            <span class="keyword"><a href="#">所有&raquo;</a></span>
            <ul>
                <?php foreach($this->listing->likes() as $item):?>
                    <li>
                        <figure>
                           <a href="<?php echo $item->user->url;?>">
                               <img src="<?php echo $this->thumbnail()->scale($item->user->photo, 54, 54);?>" alt="<?php echo $item->user->name?>">
                           </a>
                        </figure>
                        <h2><a href="<?php echo $item->user->url?>"><?php echo $item->user->name?></a></h2>
                    </li>
                <?php endforeach;?>
            </ul>
        </section>
    <?php endif;?>
    <section class="send_msg">
        <h3>发私人讯息</h3>
        <form>
        <fieldset>
        <div class="text">
        <label>名字</label>
        <input type="text">
        </div>
        <div class="text">
        <label>电邮</label>
        <input type="text">
        </div>
        <div class="textarea">
        <label>内容</label>
        <textarea></textarea>
        </div>
        <div class="button">
        <button>Send</button>
        </div>
        </fieldset>
        </form>
      </section>
    </section>
    <aside class="aside">
        <section class="user info personal">
            <figure>
                <a href="<?php echo $this->listing->user->url()?>">
                    <img src="<?php echo $this->thumbnail()->scale($this->listing->user->photo, 80, 80);?>" alt="<?php echo $this->listing->user->name?>">
                </a>
            </figure>          
            <h3><a href="<?php echo $this->listing->user->url()?>">华强北甄子丹 </a></h3>
            <p class="tel">联系电话<a href="#"><?php echo $this->listing->user->phone_number?></a></p>
            <p class="func">
            <a href="<?php echo $this->geturl('follow','follow', array('id' => (string)$this->listing->user->_id))?>" class="follow">关注</a>
                <a href="#" class="msg">发讯息</a>
            </p>
            <ul>
                <li><a href="#"><span>关注</span><?php echo (int)Model_Follow::getCountFollowers($this->listing->_id)?></a></li>
                <li><a href="#"><span>粉丝</span><?php echo (int)Model_Follow::getCountFollowing($this->listing->_id)?></a></li>
                <li><a href="#"><span>被喜欢</span><?php echo (int)Model_Like::getCountPerUser($this->listing->us)?></a></li>
            </ul>
        </section>
        <section class="ad medium"> <a href="#"><img src="images/ad_300_250.jpg"></a> </section>
        <?php if ($this->similar_ads_user2):?>
            <section class="user friend">
                <h3>他的朋友</h3>
                <span class="keyword"><a href="#">更多</a></span>
                <ul>
                    <?php foreach($this->similar_ads_user2 as $item):?>
                        <li>
                            <figure>
                                <a href="<?php echo $item->url;?>">
                                    <img src="<?php echo $this->thumbnail()->scale($item->featured_photo, 80, 80);?>" alt="<?php echo $item->title?>">
                                </a>
                            </figure>
                        <h2><a href="<?php echo $item->url[$this->getLanguagePosition()];?>" title="<?php echo $item->title?>"><?php echo mb_substr($item->title, 0, $this->current_language == 'tc' ? 15 : 22).'...';?></a></h2>
                        </li>
                    <?php endforeach;?>
                </ul>
            </section>
        <?php endif;?>
        <?php if ($this->similar_ads_user2):?>
            <section class="user post gallery">
                <h3>他的近似讯息</h3>
                <span class="keyword">
                    <a href="#">更多&raquo;</a>      
                </span>
                <ul>
                    <?php foreach($this->similar_ads_user2 as $item):?>
                        <li>
                            <dl>
                                <dt>
                                    <figure>
                                        <a href="<?php echo $item->url;?>">
                                            <img src="<?php echo $this->thumbnail()->scale($item->featured_photo, 80, 80);?>" alt="<?php echo $item->title?>">
                                        </a>
                                    </figure>
                                    <h2><a href="<?php echo $item->url[$this->getLanguagePosition()];?>" title="<?php echo $item->title?>"><?php echo mb_substr($item->title, 0, $this->current_language == 'tc' ? 15 : 22).'...';?></a></h2>
                                </dt>
                                <dd class="price"><?php echo $this->price($item, false);?>元</dd>
                                <dd class="func"> 
                                <a href="<?php echo $this->geturl('like','follow', array('id' => (string)$item->user->_id))?>" class="like">喜欢<em><?php echo Model_Like::getCount($item->_id)?></em></a><a href="<?php echo $this->geturl()?>" class="save">收藏</a>
                                </dd>
                                <dd class="user">
                                    <figure>
                                        <a href="<?php echo $item->user->url;?>">
                                            <img src="<?php echo $this->thumbnail()->scale($item->user->featured_photo, 36, 36);?>" alt="<?php echo $item->title?>">
                                        </a>
                                    </figure>
                                    <a href="<?php echo $item->user->url;?>" class="name"><?php echo $item->user->name?></a><a href="<?php echo $this->geturl('follow','follow', array('id' => (string)$item->user->_id))?>" class="follow">关注</a>
                                </dd>       
                            </dl>   
                        </li>
                    <?php endforeach;?>
                </ul>
            </section>
        <?php endif;?>

        <?php if ($this->similar_ads_user2):?>
            <section class="friend post gallery">
                <h3>你朋友的近似讯息</h3>
                <span class="keyword">
                    <a href="#">更多&raquo;</a>      
                </span>
                <ul>
                    <?php foreach($this->similar_ads_user2 as $item):?>
                        <li>
                            <dl>
                                <dt>
                                    <figure>
                                        <a href="<?php echo $item->url;?>">
                                            <img src="<?php echo $this->thumbnail()->scale($item->featured_photo, 80, 80);?>" alt="<?php echo $item->title?>">
                                        </a>
                                    </figure>
                                    <h2><a href="<?php echo $item->url[$this->getLanguagePosition()];?>" title="<?php echo $item->title?>"><?php echo mb_substr($item->title, 0, $this->current_language == 'tc' ? 15 : 22).'...';?></a></h2>
                                </dt>
                                <dd class="price"><?php echo $this->price($item, false);?>元</dd>
                                <dd class="func">
                                <a href="<?php echo $this->geturl('like','follow', array('id' => (string)$item->user->_id))?>" class="like">喜欢<em><?php echo Model_Like::getCount($this->listing->_id)?></em></a><a href="<?php echo $this->geturl()?>" class="save">收藏</a>
                                </dd>
                                <dd class="user">
                                    <figure>
                                        <a href="<?php echo $item->user->url;?>">
                                            <img src="<?php echo $this->thumbnail()->scale($item->user->featured_photo, 36, 36);?>" alt="<?php echo $item->title?>">
                                        </a>
                                    </figure>
                                    <a href="<?php echo $item->user->url;?>" class="name"><?php echo $item->user->name?></a><a href="<?php echo $this->geturl('follow','follow', array('id' => (string)$item->user->_id))?>" class="follow">关注
</a>
                                </dd>
                            </dl>
                        </li>
                    <?php endforeach;?>
                </ul>
            </section>
        <?php endif;?>


        <?php if ($this->similar_ads_other):?>
            <section class="other post gallery">
                <h3>其他人的近似讯息</h3>
                <span class="keyword">
                    <a href="#">更多&raquo;</a>      
                </span>
                <ul>
                    <?php foreach($this->similar_ads_other as $item):?>
                        <li>
                            <dl>
                                <dt>
                                    <figure>
                                        <a href="<?php echo $item->url;?>">
                                            <img src="<?php echo $this->thumbnail()->scale($item->featured_photo, 80, 80);?>" alt="<?php echo $item->title?>">
                                        </a>
                                    </figure>
                                    <h2><a href="<?php echo $item->url[$this->getLanguagePosition()];?>" title="<?php echo $item->title?>"><?php echo mb_substr($item->title, 0, $this->current_language == 'tc' ? 15 : 22).'...';?></a></h2>
                                </dt>
                                <dd class="price"><?php echo $this->price($item, false);?>元</dd>
                                <dd class="func">
                                <a href="<?php echo $this->geturl('like','follow', array('id' => (string)$item->user->_id))?>" class="like">喜欢<em><?php echo Model_Like::getCount($this->listing->_id)?></em></a><a href="<?php echo $this->geturl()?>" class="save">收藏</a>
                                </dd>
                                <dd class="user">
                                    <figure>
                                        <a href="<?php echo $item->user->url;?>">
                                            <img src="<?php echo $this->thumbnail()->scale($item->user->featured_photo, 36, 36);?>" alt="<?php echo $item->title?>">
                                        </a>
                                    </figure>
                                    <a href="<?php echo $item->user->url;?>" class="name"><?php echo $item->user->name?></a><a href="<?php echo $this->geturl('follow','follow', array('id' => (string)$item->user->_id))?>" class="follow">关注
</a>
                                </dd>
                            </dl>
                        </li>
                    <?php endforeach;?>
                </ul>
            </section>
        <?php endif;?>

        <section class="ad medium"> 
            <a href="#"><img src="images/ad_300_250.jpg"></a> 
        </section>

        <section class="city">
            <p><span>北京</span><a href="#">[切换城市]</a></p>
        </section>

        <section class="search">
            <form>
                <input type="text">
                    <button>Search</button>
            </form>
        </section>
        <section class="login">
            <ul>
                <li class="user"><figure><a href="#"><img  src="images/userThumb.jpg"></a></figure><a href="#" class="name">好运自然黎</a></li>
                <li><a href="#">宝贝</a></li>
                <li><a href="#">设置</a></li>
                <li><a href="#">登出</a></li>
            </ul>
            <p class="post new"><a href="#" class="button em">发新讯息</a></p>
        </section>
    </aside>
</article>

<?php /*
<section class="gallery hor box">
    <h3>喜欢这个分享的人还喜欢...</h3>
    <span class="keyword"> <a href="#">馒头</a> <a href="#">蜜桃</a> <a href="#">浓密</a> <a href="#">巴士</a> <a href="#">飞轮</a> <a href="#">更多&gt;</a> </span>
    <ul>
        <li>
            <dl>
                <dt>
                    <figure><a href="#"><img src="images/adDetail_pic.jpg"></a></figure>
                    <h2><a href="#">采用伯特8个月男</a></h2>
                </dt>
                <dd class="price">123,456元</dd>
                <dd class="func"> <a href="#" class="like">喜欢<em></em></a><a href="#" class="save">收藏</a></dd>
                <dd class="user"><figure><a href="#"><img src="images/userThumb.jpg"></a></figure><a class="name" href="#">李一刚志</a><a class="follow" href="#">关注</a></dd>       
            </dl>   
        </li>
    </ul>
    <section class="usersThumb">
        <h4>他们的产品大受欢迎</h4>
        <p>
            <a href="#"><img src="images/userThumb.jpg"></a>
        </p>
    </section>
</section>
*/?>

<section class="gallery hor box">
    <h3>华强北甄子丹喜欢的分享...</h3>
    <span class="keyword"> <a href="#">馒头</a> <a href="#">蜜桃</a> <a href="#">浓密</a> <a href="#">巴士</a> <a href="#">飞轮</a> <a href="#">更多&gt;</a> </span>
    <ul>
        <li>
            <dl>
                <dt>
                    <figure><a href="#"><img src="images/adDetail_pic.jpg"></a></figure>
                    <h2><a href="#">采用伯特8个月男</a></h2>
                </dt>
                <dd class="price">123,456元</dd>
                <dd class="func"> <a href="#" class="like">喜欢<em>123456</em></a><a href="#" class="save">收藏</a></dd>
                <dd class="user"><figure><a href="#"><img src="images/userThumb.jpg"></a></figure><a class="name" href="#">李一刚志</a><a class="follow" href="#">关注</a></dd>
            </dl>
        </li>
    </ul>
    <section class="usersThumb">
        <h4>他们的产品大受欢迎</h4>
            <p>
                <a href="#"><img src="images/userThumb.jpg"></a>
            </p>
    </section>
</section>


